home *** CD-ROM | disk | FTP | other *** search
/ Reverse Code Engineering RCE CD +sandman 2000 / ReverseCodeEngineeringRceCdsandman2000.iso / RCE / Library / Manuels & Misc / Softice Breakpoints / AESCU.TXT next >
Encoding:
Text File  |  2000-05-25  |  4.3 KB  |  105 lines

  1. Aescu
  2.  
  3. 1) Keygen
  4. 2) Usefull breackpoints
  5.  
  6.  
  7. KeyGens ... 
  8.  
  9. Useful tips: 
  10.  
  11.  1. The best tool to analyze a key file is an Hex Editor. Text editor are not suitable for this task. 
  12.  2. A key file is nothing more than a continuous array of bytes inside a small file. These bytes reflect the personal user
  13. information (encrypted), checksums of the key file integrity, encrypted dates, 
  14. names, addresses, encrypted flags (for instance: a flag for multi-user license), etc. 
  15.  3. To defeat a Key File Based protection scheme, you should create a little program to code a small bogus key file. This
  16. generic program should be able to create files under different names a sizes. The content of this bogus file (against most
  17. believes) must be readable information. In my 
  18. case, the bogus key file generator, cuts a large chapter from my favorite literature novel and paste it in the bogus file, adjusting
  19. the file size and name according to my necessities. Why readable information inside the bogus file? because the target program
  20. will read strategic offset locations of the key file. A readable text inside it will warn about the precise location being read at any
  21. time. It will also mark the locations where certain checksums must be added to the final key file. 
  22.  4. The key file name is in most cases, the target program main executable file name with the extension '*.key'. A very old
  23. stupidity flag still available these days. Other strategies to figure out the key file name, are the use of a string searching utility,
  24. reading the user's manual (sometimes the author will include instructions on the key file installation, revealing its name), at
  25. debugging level, bpint 21 if ah==3d (DOS), when the break occurs, execute: d (e)dx at SoftICE command screen, in windows
  26. environment, bpx CreatFile, ReadFile, GetFileAttributesA, etc., will perform the same task. 
  27. Once you have figured out the key file name, create the bogus file and copy it to the same path as the main target executable.
  28. Start the program and see what happens. If you receive an 'Invalid Key File' or 'Corrupted Key File' message (another
  29. stupidity flag), your cracking work have been greatly reduced; the next logical step is to search the location of the code where
  30. this message is triggered. 
  31.  5. The key file has to be read. There is no other alternative, the program must read the key file to test its validity. According to
  32. this, appropriate breakpoints on file reading interrupts (DOS) or API's (windows) should be set. 
  33.  
  34. SoftICE Advice: Useful Breakpoints ... 
  35.  
  36. One of the most important abilities a cracker most develop is where, when and what kind of breakpoint to set. If a perfectly
  37. timed and intelligent breakpoint is not set, then you'll grow old and die before being able to take a glimpse of the protection
  38. scheme. Remember, even the most insignificant program can contain thousands of code lines. The most important breakpoints
  39. you should know are: 
  40.  
  41. General Purposes ... 
  42.  
  43. bpx messagebox 
  44. bpx getdlgitemtext 
  45. bpx getwindowtext 
  46. bpx hmemcpy 
  47. bpx showwindow 
  48. bpx updatewindow 
  49. bmsg xxxx wm_gettext 
  50. bmsg xxxx wm_command 
  51. bmsg xxxx wm_move 
  52.  
  53. Time Related ... 
  54.  
  55. bpint 21 if ah==2A (DOS) 
  56. bpx getlocaltime 
  57. bpx getfiletime 
  58. bpx getsystemtime 
  59.  
  60. Register Flag Related (e.g. Flag on EAX) ... 
  61.  
  62. bpx cs:eip if EAX==0 (SICE 3.x) 
  63.  
  64. Memory Flag Related (e.g. Flag on 0030:000045AA) ... 
  65.  
  66. bpmb cs:eip rw if 0x30:0x45AA==0 (SICE 3.x) 
  67.  
  68. "Hear The Echo" Technique Related ... 
  69.  
  70. bpx 0x30:0x45AA do "d 0x30:0x44BB" (SICE 3.x) 
  71. bpx CS:0x66CC do "? EAX" (SICE 3.x) 
  72.  
  73. CD-ROM and Disk Based Schemes ... 
  74.  
  75. bpint 13 if ah==2 (DOS) 
  76. bpint 13 if ah==3 (DOS) 
  77. bpint 13 if ah==4 (DOS) 
  78. bpx GetFileAttributesA 
  79. bpx GetFileSize 
  80. bpx GetDriveType 
  81. bpx GetLastError 
  82. bpx ReadFile 
  83. bpio -h (Your CD-ROM Port Address) R 
  84.  
  85. Dongle Cracking ... 
  86.  
  87. bpio -h 278 R 
  88. bpio -h 378 R 
  89.  
  90. Key File Related ... 
  91.  
  92. bpint 21 if ah==3dh (DOS) 
  93. bpint 31 if ah==3fh (DOS) 
  94. bpint 21 if ah==3dh (DOS) 
  95. bpx ReadFileA 
  96. bpx CreateFileA 
  97.  
  98. Keyboard Input Related ... 
  99.  
  100. bpint 16 if ah==0 (DOS) 
  101. bpint 21 if ah==0xA (DOS) 
  102.  
  103. Possibilities are endless. I copied only those breakpoints which are considered most useful and frequently used for crackers,
  104. nevertheless, if you have a preferred breakpoint to crack certain schemes that is not listed, please let me know, I'll publish it (if
  105. worthy).